package com.ruoyi.common.mapper;

import com.ruoyi.common.core.domain.entity.PtDDLFieldEntity;
import com.ruoyi.common.core.domain.entity.PtDMLParam;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;
import java.util.Set;

public interface PtDDLMapper {

    void createTable(@Param("tableName") String table, @Param("tableCommon") String common);

    void createField(@Param("alterSql") String alterSql);

    Map<String, Object> dropTable(@Param("tableName") String tableName);

    List<Map<String, Object>> list(@Param("tableName") String table, @Param("whereList") List<String> whereList, @Param("fieldList") String fieldList);

    int insert(@Param("tableName") String tableName, @Param("keys") Set<String> keys, @Param("data") List<Map<String, Object>> data);

    int delete(@Param("tableName") String tableName, @Param("whereList") List<String> whereList);

    int update(@Param("tableName")String tableName, @Param("data") List<Map<String, Object>> data, @Param("where") Map<String, Object> where);
}
